import router from "@/router/index.js";
import { initFunction } from "./initFunction";
import { isEmpty } from "@/utils/utils";
export let routerPush = (path) => {
  router.push(path);
};
export let routerReplace = (path) => {
  router.replace(path);
};
export let routerGo = (num = 1) => {
  router.go(num);
};
export let staticPath = (path) => {
  return new URL(path, import.meta.url).href;
};
// 数据为空输出字符
export const isEmptyToCharacter = computed(
  () => (value) => (!isEmpty(value) ? "-/-" : value)
);

export const isEmptyToCharacterfn = (value) =>
  !isEmpty(value) ? "-/-" : value;
